package com.joysuch.wwyt.attendance.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.joysuch.wwyt.common.entity.UserDataEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 *
 * </p>
 *
 * @author zqw
 * @since 2022-03-03
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("wwyt_attendance_user")
@ApiModel(value = "AttendanceUser对象", description = "")
public class AttendanceUser extends UserDataEntity {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "人员id")
    private Long userId;

    @ApiModelProperty(value = "考勤组id")
    private Long groupId;

    @ApiModelProperty(value = "考勤班次id")
    private Long shiftId;

    @ApiModelProperty(value = "考勤所在周")
    private String attendanceWeek;

    @ApiModelProperty(value = "考勤所在年")
    private Integer attendanceYear;

    @ApiModelProperty(value = "考勤所在月")
    private Integer attendanceMonth;

    @ApiModelProperty(value = "考勤所在日")
    private Integer attendanceDay;

    @ApiModelProperty(value = "0 固定考勤 1排班制考勤 2自定义")
    private Integer attendanceFlag;

    public AttendanceUser(Long id, Long userId, Long groupId, Long shiftId, String attendanceWeek, Integer attendanceYear, Integer attendanceMonth, Integer attendanceDay, Integer attendanceFlag) {
        this.id = id;
        this.userId = userId;
        this.groupId = groupId;
        this.shiftId = shiftId;
        this.attendanceWeek = attendanceWeek;
        this.attendanceYear = attendanceYear;
        this.attendanceMonth = attendanceMonth;
        this.attendanceDay = attendanceDay;
        this.attendanceFlag = attendanceFlag;
    }

    public AttendanceUser() {

    }
}
